Optimal. Leaf size=79 \[ \frac {1}{2} \sqrt {a+c x^2} (2 A+B x)-\sqrt {a} A \tanh ^{-1}\left (\frac {\sqrt {a+c x^2}}{\sqrt {a}}\right )+\frac {a B \tanh ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a+c x^2}}\right )}{2 \sqrt {c}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.06, antiderivative size = 79, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 7, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.350, Rules used = {815, 844, 217, 206, 266, 63, 208} \[ \frac {1}{2} \sqrt {a+c x^2} (2 A+B x)-\sqrt {a} A \tanh ^{-1}\left (\frac {\sqrt {a+c x^2}}{\sqrt {a}}\right )+\frac {a B \tanh ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a+c x^2}}\right )}{2 \sqrt {c}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 63
Rule 206
Rule 208
Rule 217
Rule 266
Rule 815
Rule 844
Rubi steps
\begin {align*} \int \frac {(A+B x) \sqrt {a+c x^2}}{x} \, dx &=\frac {1}{2} (2 A+B x) \sqrt {a+c x^2}+\frac {\int \frac {2 a A c+a B c x}{x \sqrt {a+c x^2}} \, dx}{2 c}\\ &=\frac {1}{2} (2 A+B x) \sqrt {a+c x^2}+(a A) \int \frac {1}{x \sqrt {a+c x^2}} \, dx+\frac {1}{2} (a B) \int \frac {1}{\sqrt {a+c x^2}} \, dx\\ &=\frac {1}{2} (2 A+B x) \sqrt {a+c x^2}+\frac {1}{2} (a A) \operatorname {Subst}\left (\int \frac {1}{x \sqrt {a+c x}} \, dx,x,x^2\right )+\frac {1}{2} (a B) \operatorname {Subst}\left (\int \frac {1}{1-c x^2} \, dx,x,\frac {x}{\sqrt {a+c x^2}}\right )\\ &=\frac {1}{2} (2 A+B x) \sqrt {a+c x^2}+\frac {a B \tanh ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a+c x^2}}\right )}{2 \sqrt {c}}+\frac {(a A) \operatorname {Subst}\left (\int \frac {1}{-\frac {a}{c}+\frac {x^2}{c}} \, dx,x,\sqrt {a+c x^2}\right )}{c}\\ &=\frac {1}{2} (2 A+B x) \sqrt {a+c x^2}+\frac {a B \tanh ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a+c x^2}}\right )}{2 \sqrt {c}}-\sqrt {a} A \tanh ^{-1}\left (\frac {\sqrt {a+c x^2}}{\sqrt {a}}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.22, size = 100, normalized size = 1.27 \[ \frac {1}{2} \left (\frac {a^{3/2} B \sqrt {\frac {c x^2}{a}+1} \sinh ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{\sqrt {c} \sqrt {a+c x^2}}+\sqrt {a+c x^2} (2 A+B x)-2 \sqrt {a} A \tanh ^{-1}\left (\frac {\sqrt {a+c x^2}}{\sqrt {a}}\right )\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.97, size = 341, normalized size = 4.32 \[ \left [\frac {B a \sqrt {c} \log \left (-2 \, c x^{2} - 2 \, \sqrt {c x^{2} + a} \sqrt {c} x - a\right ) + 2 \, A \sqrt {a} c \log \left (-\frac {c x^{2} - 2 \, \sqrt {c x^{2} + a} \sqrt {a} + 2 \, a}{x^{2}}\right ) + 2 \, {\left (B c x + 2 \, A c\right )} \sqrt {c x^{2} + a}}{4 \, c}, -\frac {B a \sqrt {-c} \arctan \left (\frac {\sqrt {-c} x}{\sqrt {c x^{2} + a}}\right ) - A \sqrt {a} c \log \left (-\frac {c x^{2} - 2 \, \sqrt {c x^{2} + a} \sqrt {a} + 2 \, a}{x^{2}}\right ) - {\left (B c x + 2 \, A c\right )} \sqrt {c x^{2} + a}}{2 \, c}, \frac {4 \, A \sqrt {-a} c \arctan \left (\frac {\sqrt {-a}}{\sqrt {c x^{2} + a}}\right ) + B a \sqrt {c} \log \left (-2 \, c x^{2} - 2 \, \sqrt {c x^{2} + a} \sqrt {c} x - a\right ) + 2 \, {\left (B c x + 2 \, A c\right )} \sqrt {c x^{2} + a}}{4 \, c}, -\frac {B a \sqrt {-c} \arctan \left (\frac {\sqrt {-c} x}{\sqrt {c x^{2} + a}}\right ) - 2 \, A \sqrt {-a} c \arctan \left (\frac {\sqrt {-a}}{\sqrt {c x^{2} + a}}\right ) - {\left (B c x + 2 \, A c\right )} \sqrt {c x^{2} + a}}{2 \, c}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.20, size = 78, normalized size = 0.99 \[ \frac {2 \, A a \arctan \left (-\frac {\sqrt {c} x - \sqrt {c x^{2} + a}}{\sqrt {-a}}\right )}{\sqrt {-a}} - \frac {B a \log \left ({\left | -\sqrt {c} x + \sqrt {c x^{2} + a} \right |}\right )}{2 \, \sqrt {c}} + \frac {1}{2} \, \sqrt {c x^{2} + a} {\left (B x + 2 \, A\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.05, size = 78, normalized size = 0.99 \[ -A \sqrt {a}\, \ln \left (\frac {2 a +2 \sqrt {c \,x^{2}+a}\, \sqrt {a}}{x}\right )+\frac {B a \ln \left (\sqrt {c}\, x +\sqrt {c \,x^{2}+a}\right )}{2 \sqrt {c}}+\frac {\sqrt {c \,x^{2}+a}\, B x}{2}+\sqrt {c \,x^{2}+a}\, A \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.53, size = 59, normalized size = 0.75 \[ \frac {1}{2} \, \sqrt {c x^{2} + a} B x + \frac {B a \operatorname {arsinh}\left (\frac {c x}{\sqrt {a c}}\right )}{2 \, \sqrt {c}} - A \sqrt {a} \operatorname {arsinh}\left (\frac {a}{\sqrt {a c} {\left | x \right |}}\right ) + \sqrt {c x^{2} + a} A \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.36, size = 68, normalized size = 0.86 \[ A\,\sqrt {c\,x^2+a}-A\,\sqrt {a}\,\mathrm {atanh}\left (\frac {\sqrt {c\,x^2+a}}{\sqrt {a}}\right )+\frac {B\,x\,\sqrt {c\,x^2+a}}{2}+\frac {B\,a\,\ln \left (\sqrt {c}\,x+\sqrt {c\,x^2+a}\right )}{2\,\sqrt {c}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 6.74, size = 107, normalized size = 1.35 \[ - A \sqrt {a} \operatorname {asinh}{\left (\frac {\sqrt {a}}{\sqrt {c} x} \right )} + \frac {A a}{\sqrt {c} x \sqrt {\frac {a}{c x^{2}} + 1}} + \frac {A \sqrt {c} x}{\sqrt {\frac {a}{c x^{2}} + 1}} + \frac {B \sqrt {a} x \sqrt {1 + \frac {c x^{2}}{a}}}{2} + \frac {B a \operatorname {asinh}{\left (\frac {\sqrt {c} x}{\sqrt {a}} \right )}}{2 \sqrt {c}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________